package com.lagou.entity;

import java.io.Serializable;

public class RestResult<T> implements Serializable {
    private int status;
    private String message;
    public T data;

    public RestResult() {

    }

    public RestResult(int status, String message) {
        this.status = status;
        this.message = message;
    }

    public RestResult(T data) {
        this.data = data;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public Object getData() {
        return data;
    }

    public void setData(T data) {
        this.data = data;
    }

    @Override
    public String toString() {
        return "RestResult{" +
                "status=" + status +
                ", message='" + message + '\'' +
                ", data=" + data +
                '}';
    }
}
